package com.admin.dao;

import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.admin.entity.Stock;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.Constants;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
* 【库存信息】数据接口
* StockDao与StockDaoMapper.xml进行接口映射
* 用于扩展自定义sql方法
*/
@Repository
public interface StockDao extends BaseMapper<Stock> {
    Stock selectOne(@Param(Constants.WRAPPER) Wrapper<Stock> wrapper);
    List<Stock> selectList(@Param(Constants.WRAPPER) Wrapper<Stock> wrapper);
    IPage<Stock> selectPage(Page<Stock> page, @Param(Constants.WRAPPER) Wrapper<Stock> wrapper);
}

